﻿Public Class Prestamo : Implements IEquatable(Of Prestamo)

    Public Property Isbn As String
    Public Property Dni As String
    Public Property FechaPrestamo As String
    Public Property FechaDevolucion As String
    Public Property Entregado As Byte

    Public Sub New()

    End Sub

    Public Sub New(isbn As String, dni As String, fechaprestamo As String, fechadevolucion As String)
        Me.Isbn = isbn
        Me.Dni = dni
        Me.FechaPrestamo = fechaprestamo
        Me.FechaDevolucion = fechadevolucion
        Me.Entregado = 0

    End Sub
    Public Sub New(isbn As String, dni As String, fechaprestamo As String, fechadevolucion As String, entregado As Byte)
        Me.Isbn = isbn
        Me.Dni = dni
        Me.FechaPrestamo = fechaprestamo
        Me.FechaDevolucion = fechadevolucion
        Me.Entregado = entregado

    End Sub
    Public Overrides Function ToString() As String
        Return Me.Isbn & ", " & Me.Dni
    End Function
    Public Function Equals1(other As Prestamo) As Boolean Implements IEquatable(Of Prestamo).Equals
        Return Me.Dni = other.Dni
    End Function
End Class
